import request from '../utils/request'

const api_url = '/admin/hospital/hospitalSet'

// export default {

//   getList() {
//     return request({
//       url: `${api_name}/list`,
//       method: 'get'
//     })
//   }

// }

export function getHospitalSetList() {
  return request({
    url: `${api_url}/list`,
    method: 'get'
  })
}

export function getHospitalSetPage(pageNum, pageSize, data) {
  return request({
    url: `${api_url}/page/${pageNum}/${pageSize}`,
    method: 'post',
    data
  })
}

export function getHospitalSetById(id) {
  return request({
    url: `${api_url}/${id}`,
    method: 'get'
  })
}

export function removeHospitalSetByIds(id) {
  return request({
    url: `${api_url}/` + id,
    method: 'delete'
  })
}

export function addHospitalSet(data) {
  return request({
    url: `${api_url}`,
    method: 'post',
    data
  })
}

export function lockedHospitalSet(id, status) {
  return request({
    url: `${api_url}/locked/${id}/${status}`,
    method: 'put'
  })
}

export function editHospitalSet(data) {
  return request({
    url: `${api_url}`,
    method: 'put',
    data
  })
}
